1. Technical Field
The technical field relates to an imaging apparatus, and more particularly to an imaging apparatus having a recording function of still images and moving images and a recovery function of image data.
2. Related Art
Imaging apparatuses such as digital cameras have been in widespread use in recent years. Image data in various formats, such as still images in JPEG (Joint Photographic Experts Group) format and moving images defined by AVCHD (Advanced Video Codec High Definition) standard, can be recorded in a recording medium such as a memory card.
Meanwhile, an imaging apparatus has a problem of power-off caused by an unexpected accident, such as drop of a battery or come-off of a cable during an AC adapter usage. In this matter, the problem may be more likely to occur in recording of a moving image where a state of recording continues for a certain period of time.
As a prior art document taking into account such a problem, there is JP05-061754A. When a user data file on an external storage device is corrupted due to a power failure, a careless power switch operation, and so on, a contradiction occurs between a management part and a data part of the user data file. A data processing apparatus described in JP05-061754A checks a contradiction between the management part and the data part of each of user data files, detects corruption of the user data file, and makes a user specify a user data file in which the corruption is detected and is to be recovered.
Meanwhile, the AVCHD standard defines that a moving image file in which moving image data is recorded with a management file associated with the moving image file. The management file is a file in which profile information, and the like, of the moving image file is recorded. Hence, the management file is recorded after completing the recording of a moving image file. In the AVCHD standard, in a state in which consistency between the moving image file and the management file is not achieved, a new moving image file may not be able to be recorded because of the standard. To comply with the AVCHD standard, it is a must that a management file associated with a moving image file is always present.
When power shutdown occurs during recording of a moving image according to the AVCHD standard, a situation may occur in which, a management file associated with a moving image is not recorded even though the moving image file has been recorded. In this case, consistency is not ensured between the moving image file and the management file. Hence, for ensuring the consistency, it is necessary to create a management file so as to recover data after power recovery. However, since the creation of the management file requires analysis of the moving image file, it takes much time to recover data.
In cases where it takes much time to recover data, when power shutdown occurs during recording of a moving image, image shooting or recording may not be performed due to data recovery after power recovery. This may cause a user to miss a shooting opportunity, thus reducing user convenience.